package com.nidu.demo.role.model;

import com.nidu.demo.base.BaseTenantEntity;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

@Data
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = true)
public class RoleMenu extends BaseTenantEntity {

    private Long id;

    private Long roleId;

    private Long menuId;

    public static RoleMenu create(Long roleId, Long menuId){
        RoleMenu roleMenu = new RoleMenu();
        roleMenu.setRoleId(roleId)
                .setMenuId(menuId);
        return roleMenu;
    }
} 